import {  Message } from 'element-ui'
import router from '@/router/index';
const state = {
    isShowWord:false,
    html:""
};
const getters = {
};
const mutations = {
    SET_SHOWWORD: (state, [isShowWord,words]) => {
        state.isShowWord = isShowWord;
        state.html = words?words:state.html
        console.log(state);
    },
};

const actions = {
    set_showWord({
        commit
    }, [isShowWord,words]) {
        console.log(isShowWord,words);
        return new Promise((resolve, reject) => {   
                commit("SET_SHOWWORD",[isShowWord,words])
                resolve()
        })
    }
};
export default {
    namespaced: true,
    getters,
    state,
    mutations,
    actions,
};